package com.example.project.entity;

import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;

import com.example.project.core.domain.BaseEntity;

/**
 * 变更详情，存储journal记录的详细变更信息对象 t_journal_details
 * 
 * @author ruoyi
 * @date 2025-09-26
 */
public class JournalDetail extends BaseEntity {

	private static final long serialVersionUID = 1L;

	/** 主键ID，自增 */
	private Long id;

	/** 关联的journal记录ID */
	private Long journalId;

	/** 变更属性类型：attr=标准属性，cf=自定义字段，attachment=附件，relation=关系 */
	private String property;

	/** 属性键名：字段名、自定义字段ID、附件ID等 */
	private String propKey;

	/**
	 * 描述
	 */
	private String description;

	/** 变更前的值 */
	private String oldValue;

	/** 变更后的值 */
	private String value;

	private String showDetail;

	private Attachment attachment;

	public void setId(Long id) {
		this.id = id;
	}

	public Long getId() {
		return id;
	}

	public void setJournalId(Long journalId) {
		this.journalId = journalId;
	}

	public Long getJournalId() {
		return journalId;
	}

	public void setProperty(String property) {
		this.property = property;
	}

	public String getProperty() {
		return property;
	}

	public void setPropKey(String propKey) {
		this.propKey = propKey;
	}

	public String getPropKey() {
		return propKey;
	}

	public String getDescription() {
		return description;
	}

	public void setDescription(String description) {
		this.description = description;
	}

	public void setOldValue(String oldValue) {
		this.oldValue = oldValue;
	}

	public String getOldValue() {
		return oldValue;
	}

	public void setValue(String value) {
		this.value = value;
	}

	public String getValue() {
		return value;
	}

	public String getShowDetail() {
		return showDetail;
	}

	public void setShowDetail(String showDetail) {
		this.showDetail = showDetail;
	}

	public Attachment getAttachment() {
		return attachment;
	}

	public void setAttachment(Attachment attachment) {
		this.attachment = attachment;
	}

	@Override
	public String toString() {
		return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE).append("id", getId())
				.append("journalId", getJournalId()).append("property", getProperty()).append("propKey", getPropKey())
				.append("oldValue", getOldValue()).append("value", getValue()).toString();
	}
}
